﻿#region License
/* Copyright (C) 2009 Tim Coulter
 * 
 * This file is part of ExtremeML.
 * 
 * ExtremeML is free software: you can redistribute
 * it and/or modify it under the terms of the GNU General Public
 * License, as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 * 
 * This software is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty
 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See
 * the GNU General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with this program. If not, see http://www.gnu.org/licenses/.
*/
#endregion

using System;
using System.Xml.Linq;

namespace ExtremeML.Sdk.Vml
{
	/// <summary>
	/// Serves as the base class for class that will wrap Vml document elements.
	/// </summary>
	internal abstract class VmlElement
	{
		/// <summary>
		/// Initializes a new instance of the <see cref="VmlElement"/> class.
		/// </summary>
		/// <param name="element">An <see cref="XElement"/> from which to populate this instance.</param>
		protected VmlElement(
			XElement element)
		{
			if (element == null) throw new ArgumentNullException("element");

			Element = element;
		}

		/// <summary>
		/// Gets the contained <see cref="XElement"/> instance.
		/// </summary>
		public XElement Element { get; private set; }
	}
}